package com.ruoyi.pms.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.pms.mapper.PmsRequestDetailsMapper;
import com.ruoyi.pms.domain.PmsRequestDetails;
import com.ruoyi.pms.service.IPmsRequestDetailsService;

/**
 * 采购申请Service业务层处理
 * 
 * @author ruoyi
 * @date 2021-11-04
 */
@Service
public class PmsRequestDetailsServiceImpl implements IPmsRequestDetailsService 
{
    @Autowired
    private PmsRequestDetailsMapper pmsRequestDetailsMapper;

    /**
     * 查询采购申请
     * 
     * @param requestDetailUuid 采购申请主键
     * @return 采购申请
     */
    @Override
    public PmsRequestDetails selectPmsRequestDetailsByRequestDetailUuid(String requestDetailUuid)
    {
        return pmsRequestDetailsMapper.selectPmsRequestDetailsByRequestDetailUuid(requestDetailUuid);
    }

    /**
     * 查询采购申请列表
     * 
     * @param pmsRequestDetails 采购申请
     * @return 采购申请
     */
    @Override
    public List<PmsRequestDetails> selectPmsRequestDetailsList(PmsRequestDetails pmsRequestDetails)
    {
        return pmsRequestDetailsMapper.selectPmsRequestDetailsList(pmsRequestDetails);
    }

    /**
     * 查询采购申请列表
     *
     * @param pmsRequestDetails 采购申请
     * @return 采购申请
     */
    @Override
    public List<PmsRequestDetails> listRequestDetail(PmsRequestDetails pmsRequestDetails)
    {
        return pmsRequestDetailsMapper.listRequestDetail(pmsRequestDetails);
    }

    /**
     * 新增采购申请
     * 
     * @param pmsRequestDetails 采购申请
     * @return 结果
     */
    @Override
    public int insertPmsRequestDetails(PmsRequestDetails pmsRequestDetails)
    {
        return pmsRequestDetailsMapper.insertPmsRequestDetails(pmsRequestDetails);
    }

    /**
     * 修改采购申请
     * 
     * @param pmsRequestDetails 采购申请
     * @return 结果
     */
    @Override
    public int updatePmsRequestDetails(PmsRequestDetails pmsRequestDetails)
    {
        return pmsRequestDetailsMapper.updatePmsRequestDetails(pmsRequestDetails);
    }

    /**
     * 批量删除采购申请
     * 
     * @param requestDetailUuids 需要删除的采购申请主键
     * @return 结果
     */
    @Override
    public int deletePmsRequestDetailsByRequestDetailUuids(String[] requestDetailUuids)
    {
        return pmsRequestDetailsMapper.deletePmsRequestDetailsByRequestDetailUuids(requestDetailUuids);
    }

    /**
     * 删除采购申请信息
     * 
     * @param requestDetailUuid 采购申请主键
     * @return 结果
     */
    @Override
    public int deletePmsRequestDetailsByRequestDetailUuid(String requestDetailUuid)
    {
        return pmsRequestDetailsMapper.deletePmsRequestDetailsByRequestDetailUuid(requestDetailUuid);
    }
}
